import { request as axios } from '@/axios/index'
/**
 * 获取首页展示的公告
 */
export const noticeAtHome = () => {
    return axios({
        method: 'get',
        url: '/api/system/announcement/portal/release',
        params: {
            current: 1,
            size: 2
        }
    })
}

/**
 * 获取公告消息分页
 * @param current
 * @param size
 * @returns
 */
export const noticePage = (current: number, size = 10) => {
    return axios({
        method: 'get',
        url: '/api/system/announcement/portal/release',
        params: {
            current,
            size
        }
    })
}

export const noticeDetailedById = (id: string) => {
    return axios({
        method: 'get',
        url: `/api/system/announcement/portal/release/${id}`
    })
}
